package cn.ztydata.teachingsystem.heaven.web.dto;

import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import java.util.List;

/**
 * 课程资源dto类
 * Created by chenxin on 2014/12/18.
 */
public class CourseRscDto {
    @NotNull
    @Length(min = 1, max = 60, message = "资源名称长度应为1~60字符")
    private String name; //资源名称
    @Length(min = 1, max = 60, message = "作者名称长度应为1~60字符")
    private String author; //作者
    @NotNull
    @Min(value = 1, message = "资源类型ID不合法")
    private Long typeId; //资源类型Id
    @NotNull
    @Range(min = 0, max = 1, message = "资源种类不对")
    private Integer mold; //资源种类
    @NotNull
    @Min(value = 1, message = "专业ID不合法")
    private Long majorId; //专业ID
    @NotNull
    @Min(value = 1, message = "课程ID不合法")
    private Long courseId; //课程ID

    private String content; //知识点内容
    private String source; //资源来源
    private String remark; //资源简介

    private List<KpDto> tags;//关键字集合

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public Long getTypeId() {
        return typeId;
    }

    public void setTypeId(Long typeId) {
        this.typeId = typeId;
    }

    public Integer getMold() {
        return mold;
    }

    public void setMold(Integer mold) {
        this.mold = mold;
    }

    public Long getMajorId() {
        return majorId;
    }

    public void setMajorId(Long majorId) {
        this.majorId = majorId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getSource() {
        return source;
    }

    public void setSource(String source) {
        this.source = source;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public List<KpDto> getTags() {
        return tags;
    }

    public void setTags(List<KpDto> tags) {
        this.tags = tags;
    }

    public Long getCourseId() {
        return courseId;
    }

    public void setCourseId(Long courseId) {
        this.courseId = courseId;
    }
}
